<?php
/*
 * inc-addQuestionHome.php
 * Retral/CSCD494 Winter 2009
 * Eastern Washington University
 *
 * File Description:
 * 
 * 
 * Other:
 * 
 */

/* 
 * Set up $page_name
 * This name will be compared to PAGE_NAME in NAV_URLS table (stored in session) and verify permission for given user.
 */
$page_name = "Add Question";
$page_name = strtoupper($page_name);

// Is user logged in, and has permissions?
if (isset($_SESSION['loggedIn']) && $_SESSION['loggedIn'] !="" && $_SESSION['pagePermissions'][$page_name] == 1)
{
?>
		<link rel="stylesheet" href="css/preview.css" type="text/css" media="screen">
		<script type="text/javascript" language="javascript" src="script/addQuestion.js"></script>
		<form action="?page=addQuestion&good=true" method="POST" enctype="multipart/form-data" >
			<h2> <span class='header-text'>Add Question</span><br/> </h2>
			<p><strong> <br>Enter the number of source files that will need to be uploaded along with your new question. </strong></p>


			<p> Number of Source Files:
						<select name="numberOfSourceFiles">
							<option value="1">1</option>
							<option value="2">2</option>
							<option value="3">3</option>
							<option value="4">4</option>
							<option value="5">5</option>
							<option value="6">6</option>
							<option value="7">7</option>
							<option value="8">8</option>
							<option value="9">9</option>
							<option value="10">10</option>
							<option value="11">11</option>
							<option value="12">12</option>
							<option value="13">13</option>
							<option value="14">14</option>
							<option value="15">15</option>
							<option value="16">16</option>
							<option value="17">17</option>
							<option value="18">18</option>
							<option value="19">19</option>
							<option value="20">20</option>
						</select>
			</p>
			<p><input class='button' type='submit' value='Next' name='sourceFiles'</p>
		</form>
<?php
}
else
{
	echo "Invalid credentials";
	echo "<META http-equiv=\"refresh\" content=\"0;URL=index.php?page=login&ld=0\">";
}	
?>
